package com.lc.luzhengtang.adapter;

import android.support.annotation.Nullable;
import android.view.ViewGroup;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.lc.luzhengtang.R;
import com.zcx.helper.scale.ScaleScreenHelperFactory;

import java.util.List;

/**
 * 文 件 名: NewsListAdapter
 * 创 建 人: zhangyu
 * 创建日期: 16/12/24 19:55
 * 邮   箱: yuanchong121@gmail.com
 * 修改时间：
 * 修改备注：
 */
public class MineListAdapter_Quick extends BaseQuickAdapter<String, BaseViewHolder> {

    public String[] img_text = {"待付款", "待发货", "待收货", "待评价",
            "退款/收货"};
    public int[] imgs = {R.mipmap.daifukuan, R.mipmap.daifahuo,
            R.mipmap.daishouhuo, R.mipmap.daipingjia,
            R.mipmap.tuihuo,};

    public MineListAdapter_Quick(@Nullable List<String> data) {

        super(R.layout.item_mine, data);


    }

    @Override
    protected void convert(BaseViewHolder helper, String item) {
        ScaleScreenHelperFactory.getInstance().loadView((ViewGroup) helper.convertView);
        helper.setText(R.id.notify_text,item);
        for (int i=0;i<img_text.length;i++){
            helper.setText(R.id.text_shouhuo,img_text[i]);
        }
        for (int i=0;i<imgs.length;i++){
//            holder.imgShouhuo.setBackgroundResource(imgs[position]);
            helper.setBackgroundRes(R.id.img_shouhuo,imgs[i]);
        }


    }

   /*rivate MyOnItemClickListener itemClickListener;
    List<String> list;
    private Context context;
    public String[] img_text = {"待付款", "待发货", "待收货", "待评价",
            "退款/收货"};
    public int[] imgs = {R.mipmap.daifukuan, R.mipmap.daifahuo,
            R.mipmap.daishouhuo, R.mipmap.daipingjia,
            R.mipmap.tuihuo,};

    public MineListAdapter_Quick(Context context, List<String> list) {
        this.context = context;
        this.list = list;
    }
*/

}
